import { API_LIST } from '../../../Api/Api'
import { commonTableList, BuiltInData } from '../Common/common'

export const GantryCrane = async ({ OptionsEvent, oneData, Permission, actionRef, ClientData }) => {
    let dataList = {
        hideInSearch: true,
        pageSize: 10,
        params: { gantryCraneUuid: oneData.uuid },
        get: API_LIST()['getLabGantryCraneOrganizationConstrained'],
        columns: [
            commonTableList.uuid,
            {
                dataIndex: 'id',
                title: 'id',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'imei',
                title: '仪表唯一编号',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'equipmentName',
                title: '设备名称',
                valueType: 'input',
                width: 400,
            },
            {
                dataIndex: 'sectionId',
                title: '标段id',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'timestamp',
                title: '时间戳',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'windSpeed',
                title: '环境风速',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'windLevel',
                title: '风级',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'windState',
                title: '风速状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainhookCycCnt',
                title: '主钩工作循环',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxhookCycCnt',
                title: '副钩工作循环',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainOverloadCnt',
                title: '主钩超载次数',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxOverloadCnt',
                title: '副钩超载次数',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'lastWorkedTime',
                title: '仪表累计通电时间',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'nowWorkedTime',
                title: '仪表当前通电时间',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainWeight',
                title: '主钩重量',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainWeightState',
                title: '主钩重量状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'auxWeight',
                title: '副钩重量',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxWeightState',
                title: '副钩重量状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainDistance',
                title: '大车行程',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainDistanceState',
                title: '大车行程状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'auxDistance',
                title: '小车行程',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxDistanceState',
                title: '小车行程状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainHeight',
                title: '主钩高度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainHeightState',
                title: '主钩高度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainSpeed',
                title: '主钩速度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainSpeedState',
                title: '主钩速度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'auxHeight',
                title: '副钩高度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxHeightState',
                title: '副钩高度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'auxSpeed',
                title: '副钩速度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxSpeedState',
                title: '副钩速度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'uploadTime',
                title: '数据时间',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'onlineState',
                title: '在线状态',
                valueType: 'select',
                valueEnum: BuiltInData.online,
                width: 150,
            },
            {
                dataIndex: 'mainCartSpeed',
                title: '大车速度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxCartSpeed',
                title: '小车速度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'girderAngle',
                title: '主梁角度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'anteriorRamusAngle',
                title: '前支角度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'middleBranchAngle',
                title: '中支角度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'afterBranchAngle',
                title: '后支角度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainWeight2',
                title: '主钩2重量',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainWeightState2',
                title: '主钩2重量状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainHeight2',
                title: '主钩2高度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainHeightState2',
                title: '主钩2高度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'mainSpeed2',
                title: '主钩2起升速度',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'mainSpeedState2',
                title: '主钩2起升速度状态',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'auxDistance2',
                title: '小车2行程',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'auxDistanceState2',
                title: '小车2行程状态2',
                valueType: 'select',
                valueEnum: BuiltInData.earlyWarning,
                width: 150,
            },
            {
                dataIndex: 'craneDeflection',
                title: '大车偏斜',
                valueType: 'input',
                width: 150,
            },
            {
                dataIndex: 'workCycleFactor',
                title: '工作循环系数',
                valueType: 'input',
                width: 150,
            },
        ],
    }
    return dataList
}
